package services

import (
	"fmt"
	"longmen/server/pkg/common/helper/util"
	"longmen/server/pkg/db/mysql/db_main"
	"longmen/server/pkg/db/mysql/models/models_main"
)

func (s *Service) GetPriceList() ([]*models_main.GoldPrice, error) {
	fName := "GetPriceList"
	list, err := db_main.GetGoldPricesParam(map[string]interface{}{}, "sequence asc")
	if err != nil {
		return nil, fmt.Errorf("%s%s", util.Convert(fName), err.Error())
	}
	return list, nil
}
